Release 10.1A: OpenEdge Data Management:
DataServer for ORACLE
Unsupported 4GL statements
The DataServer supplies you with the complete functionality of the Progress 4GL when accessing ORACLE databases. Nearly all 4GL language elements (statements, functions, etc.) and Data Dictionary features work the same whether your application accesses an ORACLE database through the DataServer or an OpenEdge database. You can use the
DBRESTRICTIONSfunction to find out which Progress 4GL features that your non-OpenEdge databases, or specific tables in those databases, do not support.For the DataServer for ORACLE,
DBRESTRICTIONScan returnRECID,PREV,LAST,SETUSERID,SET-CURRENT-VALUE. If you connected to the logical database in read-only mode, the function returnsREAD-ONLYfor the schema holder connection, not for the connection to the ORACLE database. You can specify-ROin the connection to ORACLE; in that case, the function returnsREAD-ONLYfor the ORACLE database as well. See the “DBRESTRICTIONS function” reference entry in OpenEdge Development: Progress 4GL Reference for information on syntax.Table 2–10 lists some of the 4GL statements and functions that behave differently between the OpenEdge DataServer for ORACLE and a native OpenEdge database.
Table 2–10: Progress 4GL and ORACLE differences Feature DescriptionBEGINSfunction
Abbreviated IndexUSINGoption When you use these 4GL elements to access data in an ORACLE database, you will have different results than you would expect from the Progress 4GL in the following case. If you have a customer named SI and one named SIM and you issue thisFINDstatement:
FIND customer WHERE name BEGINS "SI"The Progress 4GL returns the customer named SI; with the DataServer, the find fails because it is considered ambiguous. You receive the same results when you use an abbreviated index or theUSINGoption in your query.BEGINSoperatorMATCHESfunction To resolveBEGINSorMATCHEScomparisons, ORACLE does not use an index as the Progress 4GL does. Instead, it might do a complete table scan. The table scan typically occurs when the ORACLE DBMS does not know the value of the pattern when the SQL is compiled. See the "Query tuning" section for information on using theNO-BINDoption to handle this situation.
Do not use theMATCHESorBEGINSfunction with a pattern that is not an expression, but is stored in the ORACLE database. Although theoretically possible with the Progress 4GL, using this kind of criteria results in poor performance with an OpenEdge database.CONTAINSoperator This option relates to word-indexing, which the DataServer does not support. It returns a compilation error.COUNT-OFfunction The DataServer does not support this function.CREATEstatement Records you create after a cursor was opened might be invisible to that cursor. ORACLE maintains a view of a database’s state at the time when the user opens a cursor. Changes you make to a database after opening a cursor might not be visible.CURRENT-VALUEfunction You can useCURRENT-VALUEonly after you have successfully called theNEXT-VALUEfunction.CURRENT-VALUEstatement The OpenEdge DataServer for ORACLE does not support setting a sequence generator’s current value.DBTASKIDfunction The OpenEdge DataServer for ORACLE does not support this function.FINDstatementsQUERYoption To reduce the number of records ORACLE includes in the results set, you should qualify yourFINDstatements and queries with aWHEREclause. This achieves a performance rate that is closer to OpenEdge performance. For better performance, use theDEFINEQUERYstatement instead ofFIND.
To control the order of the results, include theUSE-INDEXorBYoptions in your queries.MATCHESfunction If you want to use theMATCHESfunction for a string containing double-byte characters, you must fill out the character expression with periods (.). For example, where J is a double-byte character, the following statement does not find a match:
FIND customer WHERE name BEGINS "SI"Add periods to search the entire field. For a field that is defined as 20 bytes long, to adjust the example, include seventeen periods after the single double-byte character, J.OPENQUERYstatement Newly created records might not appear in the results set of queries that you opened before you created the records. Reopen the query to access the new records.INDEXEDREPOSITIONclause Index reposition might cause new SQL to be executed thereby causing newly created records to appear.SESSION:TIME-SOURCEhandle This system handle returns the ORACLE server’s time information.SETUSERIDfunction You cannot use this function to change the user ID and password of an ORACLE login.SHARE-LOCKoption You cannot use this option for a query with theFIELDSoption.SHARE-LOCKisNO-LOCKfor ORACLE. Time in theWHEREclause The Progress 4GL supports this option only if you have mapped ORACLEDATEcolumns to the OpenEdgeCHARACTERfields in the schema image.USERIDfunction For a connection to an ORACLE database, theUSERIDfunction returns the value that you specified for the-Uparameter. For example, if you specify-U bob/password,USERIDreturnsbob/password.
|
Copyright © 2005 Progress Software Corporation www.progress.com Voice: (781) 280-4000 Fax: (781) 280-4095 |